/**
 * Copyright (c) 2014-2016 www.nryuncang.com. All Rights Reserved.
 */
package com.topisv.tms.repository.qimen;

import java.util.List;

import org.springframework.data.jpa.repository.JpaSpecificationExecutor;
import org.springframework.data.jpa.repository.Query;
import org.springframework.data.repository.PagingAndSortingRepository;

import com.topisv.tms.entity.qimen.OrderProcessConfig;

/**
 * 
 *
 * @author <a href=mailto:zhangweize@nryuncang.com>zhangweize</a>
 * @version 1.0.0
 */
public interface OrderProcessConfigDao  extends PagingAndSortingRepository<OrderProcessConfig, Long>, JpaSpecificationExecutor<OrderProcessConfig> {

	@Query("select t from OrderProcessConfig t where warehouseCode = ?1")
	OrderProcessConfig findOrderProcessConfigByWarehouse(String warehouseCode);
	
	@Query("select t from OrderProcessConfig t where dealIp = ?1")
	List<OrderProcessConfig> findOrderProcessConfigByIp(String ip);
}
